package model;
import java.awt.BasicStroke;
import java.awt.Color;
import java.awt.Graphics;
import java.awt.Graphics2D;
import java.awt.Point;
import java.awt.Shape;
import java.awt.geom.CubicCurve2D;

import view.BoundBox;


public class DrawBezier extends DrawObject
{

	public DrawBezier(String tmpL) 
	{
		String [] param = tmpL.split(" ");
		
		this.type =  param[0].charAt(0);
		
		this.setX1( new Integer(param[1]) );
		this.setY1( new Integer(param[2]) );
		
		this.setX2( new Integer(param[3]) );
		this.setY2( new Integer(param[4]) );
		
		this.setX3( new Integer(param[5]) );
		this.setY3( new Integer(param[6]) );
		
		this.setX4( new Integer(param[7]) );
		this.setY4( new Integer(param[8]) );
		
		this.setThickness( new Integer(param[9]) );
		
		this.setRed( new Integer(param[10]) );
		this.setGreen( new Integer(param[11]) );
		this.setBlue( new Integer(param[12]) );
	}
	
	
	public DrawBezier(DrawObject obj) 
	{
		super (obj);
	}


	@Override
	public String toString()
	{
		String tmp = new String();
		
		tmp = 			this.type 
				+ " " + this.getX1()
				+ " " + this.getY1()
				+ " " + this.getX2()
				+ " " + this.getY2()
				+ " " + this.getX3()
				+ " " + this.getY3()
				+ " " + this.getX4()
				+ " " + this.getY4()
				+ " " + this.getThickness()
				+ " " + this.getRed()
				+ " " + this.getGreen()
				+ " " + this.getBlue();
		
		return tmp;
	}

}
